package controller

import (
	"bluebell/logic"
	"bluebell/utils"
	"fmt"
	"github.com/gin-gonic/gin"
	"go.uber.org/zap"
)

func CommunityHandler(c *gin.Context) {
	data, err := logic.GetCommunityList()
	if err != nil {
		fmt.Printf("%v\n", err)
		zap.L().Error("login.getAllCommunit() 失败", zap.Error(err))
		utils.ResponseError(c, utils.CodeServerBusy)
		return
	}
	utils.ResponseSuccess(c, data)

}
